The present invention relates generally to a system and method for calibrating contact operation time of a relay that is substantially coincident with a current zero-crossing of an input power signal. More particularly, the present invention relates to calibrating the contact closure times of each of a number of individual relays, and storing the calibration factor of a selected relay within the microprocessor of a sensor which employs the selected relay, to ensure contact closure at substantially the current zero-crossing of the input power supply.
Many commercial, industrial, and government facilities requite a significant number of lighting fixtures for adequate illumination, and therefore use a significant amount of power to operate the fixtures. To reduce the power consumed to light these facilities, a number of lighting control systems are used which employ sensors to automatically and selectively power the light fixtures on and off.
The sensors generally employ relays in order to control the supply of power to the light fixture, depending on room occupancy and time of day, among other factors. The sensor life can be greatly extended if the relay contacts close at substantially a current zero-crossing of the input power signal.
In order to facilitate the coincidental timing of the contact closure with zero-crossing, various errors need to be calibrated. These errors can include, for example, a relay-dependent variation in time between initiating contact closure and actual contact closure, depending on variation in power supply voltage from a nominal power supply. In other words, there are unit-to-unit variations among multiple relays with respect to the time that elapses between the input signal energizing a relay drive circuit and actual contact closure. Relay energization time variations can be as much as xc2x10.42 milliseconds (msec.) with a nominal supply voltage of 13.9 VDC. Additionally, an error of as much as xc2x10.48 msec. results from the power supply variation. For example, the range for power supply variations is from 12.6 VDC to 15.1 VDC, nominal and non-nominal, respectively. An additional error (e.g., as much as xc2x10.24 msec.) results from microcontroller threshold changes due to microcontroller activation time variations. The above-mentioned errors (e.g., microcontroller threshold variation errors, relay energization time errors, and power supply voltage variation) are cumulative and fixed for a single sensor. The calibration of all three of these errors would greatly increase the life of the relay, and therefore the sensor. Thus, a need exists for a method of calibrating the relay contact closure point on a per-relay basis such that contact closure is substantially coincidental with a current zero-crossing of an input power signal regardless of microcontroller threshold variation errors, relay energization time errors, and power supply voltage variation.
As mentioned above, the combinations of various power supplies, microprocessors or microcontrollers and associated relays present unique errors. Accordingly, conventional methods of calibrating multiple relays (e.g., an entire lot of relays during their manufacture) with the offset timing error from one relay does not compensate for the error contributed by each relay which, as discussed above, can vary greatly and therefore shorten the sensor life.
The present invention overcomes the deficiencies of existing relays within control systems and realizes a number of advantages over conventional relay-operated control systems. A system is provided in accordance with the present invention that calibrates offset error for individual relays and stores the offset error of a particular relay in, for example, the microcontroller of a sensor within a control system (e.g. in a lighting control system) to facilitate contact operation at substantially the current zero-crossing of an input power signal. A method is provided for deploying a plurality of relays in respective control systems (e.g., sensors for light fixtures) which comprises testing contacts of respective relays, storing the corresponding calibrated contact operation times in a memory device, and transferring each of the offset times to a processing device such as the memory (e.g., EEPROM) provided within a microcontroller for the respective control device in which the corresponding relay is deployed.
The present invention also provides a method for determining timing of contact operation of a relay. The method comprises generating a relay test request signal, for example, a plurality of pulses occurring in a pre-determined pattern (e.g., at substantially the current zero-crossing), initiating operation of the contacts of the relay in response to one of the pulses, and determining the amount of time required for contact operation in response to the pulse (e.g., the time difference between zero-cross and contact closure). The method comprises determining whether the amount of time for the relay to operate is greater than the time between the pulses, and storing the amount of time for the relay to operate in a memory device if the amount of time for the relay to operate is less than the time between pulses. A microcontroller or other processing device can be programmed to employ the time difference as a calibration factor to be added to or subtracted from the time when a non-calibrated relay control signal initiates the contacts. The calibration factor can also take into account variations associated with the power supply and the processing device (e.g., processing time corresponding to relay control operations).
The present invention also provides an apparatus for testing contact operation of a relay within a control system. The apparatus comprises a memory device and a processing device, such as a microcontroller containing an EEPROM, operable to store an amount of time corresponding to the time needed to enable the relay contacts to operate, as well as an interface circuit between the control system and the processing device. During relay production, the control system is coupled to the apparatus via the interface circuit.
In accordance with an aspect of the present invention, the control system employs a microcontroller with a calibrated value of the contact operation time corresponding to the particular relay, power supply, and the microcontroller, which is employed by a relay-operated sensor within the control system.
In accordance with another aspect of the present invention, the calibrated value of the contact operation time corresponds to the offset timing of contact operation compared to the zero-crossing of the incoming power signal.
In accordance with yet another aspect of the invention, the offset of contact operation time compared to a zero-crossing is measured several times, and the average value is then provided into the microcontroller or other processing device of the control system.